import { Component, EventEmitter, Output } from '@angular/core';
import { SrmConfig } from 'src/components/scenarios/models';

@Component({
  selector: 'app-srm-setting',
  templateUrl: './srm-setting.component.html',
  styleUrl: './srm-setting.component.scss'
})
export class SrmSettingComponent {
  sidebarRightVisible: boolean = false;
  item?: SrmConfig;
  @Output()
  onHide: EventEmitter<SrmConfig> = new EventEmitter();

  onEdit(item: SrmConfig) {
    this.item = item;
    this.sidebarRightVisible = true;
  }
  onSidebarHide() {
    this.onHide.next(this.item!);
  }
}
